<template>
  <div class="body">
    <van-sticky>
      <!-- 会员中心 -->
      <div class="nav">
        <div></div>
        <div>会员中心</div>
        <div></div>
      </div>
    </van-sticky>

    <!-- 登录 -->
    <div class="header" :style="{ backgroundImage: bg }">
      <div class="top">
        <div class="iconfont">
          <!-- 图标 -->
          <div class="icon-denglu1"></div>
          <!-- 登录 -->
          <div class="user">
            <div class="userName">
              <div class="name">请登录</div>
              <div class="name-up" @click="$router.push('/login')">登录</div>
            </div>
          </div>
        </div>
      </div>
      <!-- bottom -->
      <div class="bottom">
        <div class="children-item">
          <div>{{ jf }}</div>
          <div>积分</div>
        </div>
        <div class="children-item">
          <div>0</div>
          <div>购物券</div>
        </div>
        <div class="children-item">
          <div>0</div>
          <div>兴币</div>
        </div>
      </div>
      <!-- 设置 -->
      <div class="set">
        <div class="iconfont icon-shezhi"></div>
      </div>
      <!-- 订单 -->
      <div class="box">
        <div class="box-header">
          <div class="spcell">
            <span class="title">我的订单</span>
          </div>
          <div style="flex: 1"></div>
          <div class="right" @click="$router.push('/order')">
            <span>全部订单</span>
            <span
              style="
                font-size: 0.512rem;
                color: #666;
                width: 12px;
                height: 19px;
                margin-left: 10px;
              "
              >></span
            >
          </div>

          <div class="border-bottom">
            <div class="children-item">
              <div
                class="iconfont icon-weibiaoti-"
                style="color: pink; font-size: 22px"
              ></div>
              <div class="wenzi">待付款</div>
            </div>
            <div class="children-item">
              <div
                class="iconfont icon-daifahuo"
                style="color: yellow; font-size: 22px"
              ></div>
              <div class="wenzi">待发货</div>
            </div>
            <div class="children-item">
              <div
                class="iconfont icon-daishouhuo"
                style="color: skyblue; font-size: 22px"
              ></div>
              <div class="wenzi">待收货</div>
            </div>
            <div class="children-item">
              <div
                class="iconfont icon-31daipingjia"
                style="color: blue; font-size: 22px"
              ></div>
              <div class="wenzi">待评价</div>
            </div>
          </div>
        </div>
      </div>
      <!-- 中兴 -->
      <div class="phone">
        <img
          src="https://image.ztemall.com/b3eba55e759452cbe76e999239c47087.jpg"
          alt=""
        />
      </div>
      <!-- 优惠券 -->
      <div class="money">
        <div class="children-item">
          <div
            class="iconfont icon-youhuiquan"
            style="color: orange; font-size: 22px"
          ></div>
          <div class="wenzi">我的优惠券</div>
        </div>
        <div class="children-item">
          <div
            class="iconfont icon-dizhi"
            style="color: blue; font-size: 22px"
          ></div>
          <div class="wenzi">我的地址</div>
        </div>
        <div class="children-item">
          <div
            class="iconfont icon-xiaoshou-"
            style="color: skyblue; font-size: 22px"
          ></div>
          <div class="wenzi">我的售后</div>
        </div>
      </div>
      <!-- 网点 -->
      <div class="new">
        <div class="children-item">
          <div
            class="iconfont icon-xiaoshou-"
            style="color: #a263e3; font-size: 22px"
          ></div>
          <div class="wenzi">销售网点</div>
        </div>
        <div class="children-item">
          <div
            class="iconfont icon-zhuceyouli"
            style="color: red; font-size: 22px"
          ></div>
          <div class="wenzi">邀请礼物</div>
        </div>
        <div class="children-item">
          <div
            class="iconfont icon-shoucang"
            style="color: yellow; font-size: 22px"
          ></div>
          <div class="wenzi">我的收藏</div>
        </div>
        <div class="children-item">
          <div
            class="iconfont icon-31daipingjia"
            style="color: green; font-size: 22px"
          ></div>
          <div class="wenzi">我的评价</div>
        </div>
        <div class="children-item">
          <div
            class="iconfont icon-lingdang"
            style="color: yellow; font-size: 22px"
          ></div>
          <div class="wenzi">我的预约</div>
        </div>
        <div class="children-item">
          <div
            class="iconfont icon-008-kuaidixianghuishou"
            style="color: green; font-size: 22px"
          ></div>
          <div class="wenzi">我的回收</div>
        </div>
      </div>
    </div>
  </div>
</template>

<script>
import "../../public/font_3498623_keoq015leda/iconfont.css";
import "../../public/font_3498623_kqiy6z7cgqd/iconfont.css";
import "../../public/font_3498623_r40iatoft9n/iconfont.css";
import "../../public/font_3498623_nrs55z5jird/iconfont.css";
import Vue from "vue";
import { Sticky } from "vant";
Vue.use(Sticky);
export default {
  data() {
    return {
      jf: 0,
      bg: "linear-gradient(0deg, #fd8286 0, #e14247 99%)",
    };
  },
  created() {
    if (localStorage.getItem("token")) {
      this.jf = 1000;
      this.bg = "linear-gradient(0deg,#47e4fc 0,#1392e3 100%)";
    }
  },
};
</script>

<style lang="scss" scoped>
.header .set .iconfont {
  font-size: 20px !important;
}
.body {
  height: 115%;
  background-color: rgb(226, 225, 225);
}
.nav {
  height: 46px;
  background-color: #fff;
  display: flex;
  justify-content: space-between;
  text-align: center;
  line-height: 46px;
  font-size: 18px;
}
.header {
  width: 375px;
  height: 300px;
  border-radius: 0 0 0.64rem 0.64rem;
  .top {
    height: 160px;
    .iconfont {
      display: -webkit-flex;
      display: flex;
      -webkit-align-items: center;
      align-items: center;
      padding: 80px 14px 20px;
      height: 2.77333rem;
      line-height: 2.77333rem;
      width: 100%;
      position: relative;
      .icon-denglu1 {
        height: 2.73067rem;
        text-align: right;
        color: #fff;
        font-size: 70px;
        padding-left: 30px;
      }
      .user {
        width: 320px;
        height: 65px;
        /* background-color: aquamarine; */
        padding-left: 3px;
        color: #fff;
        -webkit-flex: 1;
        flex: 1;
        display: -webkit-flex;
        display: flex;
        height: 2.77333rem;
        line-height: 2.77333rem;
        .userName {
          display: flex;
          .name-up {
            width: 54px;
            height: 30px;
            margin-left: 100px;
            margin-top: 8px;
            border: 0.02133rem solid #fff;
            border-radius: 0.74667rem;
            line-height: 30px;
            padding-left: 10px;
          }
        }
      }
    }
  }
  .bottom {
    /* margin-top: -30px; */
    /* width: 352px; */
    height: 53px;
    /* background-color: aqua; */
    display: flex;
    justify-content: space-around;
    width: 94%;
    margin: auto;
    /* border-bottom-left-radius: 0.64rem;
    border-bottom-right-radius: 0.64rem; */
    .children-item {
      position: relative;
      text-align: center;
      color: #fff;
      margin-bottom: 0.17067rem;
      font-size: 16px;
    }
  }
  .set {
    position: absolute;
    right: 0.42667rem;
    top: 60px;
    left: 320px;
    box-sizing: border-box;
    text-align: center;
    font-size: 0.896rem;
    color: #fff;
    .iconfont {
      font-size: 26px;
    }
  }
  .box {
    width: 355px;
    height: 120px;
    margin: auto;
    background: #fff;
    border-radius: 0.64rem;
    overflow: hidden;
    margin-bottom: 0.42667rem;
    margin-top: 30px;
    position: relative;
    /* background-color: aqua; */
    .box-header {
      width: 355px;
      height: 57px;
    }
    .spcell {
      margin-top: 0.256rem;
      border-radius: 0.704rem;
      padding: 0.512rem 0.68267rem;
      display: -webkit-flex;
      display: flex;
      -webkit-align-items: center;
      align-items: center;
      padding: 0.42667rem 0.42667rem 1.06667rem;
      float: left;
      .title {
        font-size: 0.59733rem;
        margin-left: 16px;
        color: #000;
        font-size: 14px;
        margin-top: 10px;
      }
    }
    .right {
      font-size: 18px;
      padding-left: 180px;
      margin-top: 20px;
      font-size: 0.53333rem;
      color: #666;
      display: inline-block;
      font-family: iconfont;
      font-weight: 400;
      font-variant: normal;
      text-transform: none;
      text-rendering: auto;
      /* line-height: 1; */
      vertical-align: middle;
      /* content: "\e913"; */
    }
    .border-bottom {
      display: flex;
      justify-content: space-around;
      margin: auto;
      border-bottom-left-radius: 0.64rem;
      border-bottom-right-radius: 0.64rem;
      margin-bottom: 0.42667rem;
      background: #fff;
      position: relative;
      width: 100%;
      .children-item {
        text-align: center;
        .wenzi {
          font-size: 12px;
          color: #666;
        }
      }
    }
  }
  .phone {
    display: block;
    width: 94%;
    height: auto;
    margin: auto;
    border-top-left-radius: 0.64rem;
    border-top-right-radius: 0.64rem;
    overflow: hidden;
    position: relative;
    font-size: 0;
    img {
      width: 100%;
    }
  }
  .money {
    display: flex;
    justify-content: space-around;
    background: #fff;
    width: 94%;
    margin: auto;
    border-bottom-left-radius: 0.64rem;
    border-bottom-right-radius: 0.64rem;
    margin-bottom: 0.42667rem;
    .children-item {
      position: relative;
      padding: 0.64rem 0;
      text-align: center;
      color: #666;
    }
  }
  .new {
    width: 352px;
    height: 150px;
    display: flex;
    background: #fff;
    width: 94%;
    margin: auto;
    border-bottom-left-radius: 0.64rem;
    border-bottom-right-radius: 0.64rem;
    margin-bottom: 0.42667rem;
    border-top-left-radius: 0.64rem;
    border-top-right-radius: 0.64rem;
    justify-content: flex-start !important;
    flex-wrap: wrap;
    .children-item {
      width: 25%;
      position: relative;
      padding: 0.64rem 0;
      text-align: center;
      color: #666;
      .iconfont {
        text-align: center;
        height: 30px;
        margin: auto;
        line-height: normal;
      }
    }
  }
}
</style>
